﻿package ygg.printer
{
	import j.sus2maj7.printer.*;
	import j.sus2maj7.context.*;
	
	import ygg.encoding.swf.abc.object.*;
	
	public class AbcPrinterFactory extends AbstractPrinterFactory
	{
		
		override public function getPrinter(o:*, context:IContext = null):IPrinter
		{
			var retVal:IPrinter;
			
			if (o is Class_)
			{
				retVal = new ClassPrinter();
			}
			/*else if (o is Instance)
			{
				retVal = new InstancePrinter();
			}*/
			else if (o is Variable)
			{
				retVal = new VariablePrinter();
			}
			else if (o is Constant)
			{
				retVal = new ConstantPrinter();
			}
			else if (o is Method)
			{
				retVal = new MethodPrinter();
			}
			else if (o is Function_)
			{
				retVal = new MethodPrinter();
			}
			else
			{
				
			}
			
			
			return retVal;
		}
	}
}